package com.heima.pojo;

import lombok.Data;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Component;

@Data
@Component
public class Person {
    @Value("${bean2[0].id}")
    private Integer id;
    @Value("${bean2[0].name}")
    private String name;
    @Value("${bean2[0].sex}")
    private String sex;
}
